package br.com.dbsti.projetofinal;

import br.com.dbsti.agenda.Contato;
import br.com.dbsti.agenda.Empresa;
import br.com.winesys.geta.GeTA;
import br.com.winesys.geta.base.UIManagerPreparer;
import br.com.winesys.geta.persistence.jpa.JPAEntityManagerFactoryBuilder;
import java.awt.Dimension;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;

public class App {

    public static void main(String[] args) {
        UIManagerPreparer.loadDeveloperDefaults();
        try {
            UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
        } catch (Exception ex) {
            Logger.getLogger(App.class.getName()).log(Level.SEVERE, null, ex);
        }
        JPAEntityManagerFactoryBuilder.configure("agenda", System.getProperties());
        GeTA.createCadastroUnico(Empresa.class, null, 
                "Caddastro de Empresas").run();
        GeTA.createCadastroPopup(Contato.class, null, 
                "Cadastro de Contatos", new Dimension(800,600)).run();
        
    }
}
